#include <iostream>

int main() {
   int n,i;
    scanf("%d\n",&n);
    for (int j = 2; j < 10000; ++j) {
        if (j%n == 2){
            printf("%d\n",j);
        }
    }
    return 0;
}
